

#include"i2c_management.h"
void i2c_command_handler(uint8_t* array){

	switch (array[0]) {
	case REG_SERVO0:
		servo_val_set(array[1], TIMER3_PERIOD, SERVO_BY_PORT_B1);
		break;
	case REG_SERVO1:
		servo_val_set(array[1], TIMER3_PERIOD, SERVO_BY_PORT_B0);
		break;
	case REG_MOTOR_MODE:
		mtr_mode = array[1];
		break;
	case REG_ENGINE_PARAM:
		change_pid_param(work_param_ptr, array);
		break;
	case REG_PARROT_A:
		mtr_change_parrot(motorA_ptr, array);
		break;
	}

}
